package com.endpoint.book.service;

import com.endpoint.book.dto.BookChapterAboutRespDto;
import com.endpoint.book.dto.BookCommentRespDto;
import com.endpoint.book.dto.BookRespDto;
import com.endpoint.book.entity.Book;
import com.baomidou.mybatisplus.extension.service.IService;

import java.security.NoSuchAlgorithmException;
import java.util.List;

/**
 * <p>
 * 小说表 服务类
 * </p>
 *
 * @author Jack_Li
 * @since 2024-07-03
 */
public interface BookService extends IService<Book> {

    public List<Book> listByIds(List<Long> ids);

    public List<Book> updateRankList();

    public BookRespDto getBookById(Long id);

    public List<BookRespDto> listRecBooks(Long bookId) throws NoSuchAlgorithmException;

    public BookChapterAboutRespDto getLastChapterAbout(Long bookId);

    public BookCommentRespDto listNewestComments(Long bookId);

    public void addVisitCount(Long bookId ,int addCount);

}
